<template>
    <view class="bottom-navigate">
     <div style="position: relative; width: 50%;" @click="redirect('/pages/index/indexPage/indexPage' )">
		       <div  style="position: absolute;left: 163rpx; width: 50rpx;height:43rpx ;top: 1.5rpx;" class="geren">
				   <img src="/static/homepage/homepage.png" alt=""></div>
		       <div class="word2">首页</div>
	 </div>
           <div style="position: relative;width: 50%;" @click="redirect('/pages/index/profilePage/profilePage' )" >
		   <div  style="position: absolute;left: 165rpx; width: 50rpx;height:43rpx ;top: 0rpx;" class="geren">
			   <img style="width: 90%;height: 107%;" src="/static/homepage/infor.png" alt=""></div>
		   <div class="word2">个人</div></div>
    </view>
</template>

<script>
export default {
    name: "bottomNavigate",
    mounted() {
        console.log("bottomNavigate mounted");
    },
    onload(){
        console.log("bottomNavigate onload");
    },
    methods: {
        redirect(url){
            let currentPage = getCurrentPages();
            // console.log(currentPage[currentPage.length-1].route);
            if (url != "/"+currentPage[currentPage.length-1].route) {
                uni.redirectTo({ url: url ,animationType:"none"});
            }
            
        },
        
    },
    
}
</script>

<style scoped>
	.word2{margin: 0 auto;
		padding-top: 55rpx;
		height: 20rpx;
		width: 50rpx;
		font-size: 25rpx;
font-family: Adobe Heiti Std;
font-weight: normal;
color: #535353;
line-height: 20rpx;}
	.geren img{height: 100%;width: 100%;}
.bottom-navigate {
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 125rpx;
    background-color: #fff;
    display: flex;
    justify-content: space-around;
    align-items: center;
    border-top: 1rpx solid #e5e5e5;
}
</style>